import DocInner from 'doc.inner'
import HztechCommon from 'hztech.common'
import Vue from 'vue'
import mobileComponents from './components/mobile/index'
import webComponents from './components/web/index'

function globalRegisterComopnent(componentsObj) {
  Object.keys(componentsObj).forEach(componentName => {
    const component = componentsObj[componentName]
    Vue.component(component.name, component)
  })
}
globalRegisterComopnent(mobileComponents)
globalRegisterComopnent(webComponents)

export default ({ Vue, options, router }) => {
  Vue.use(DocInner);
  Vue.use(HztechCommon);
};
